package com.ruoyi.gcgl.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.ruoyi.common.core.text.Convert;
import com.ruoyi.gcgl.domain.GcProjectFlow;
import com.ruoyi.gcgl.mapper.GcProjectFlowMapper;
import com.ruoyi.gcgl.service.IGcProjectFlowService;

/**
 * 工程流程图Service业务层处理
 * 
 * @author ruoyi
 * @date 2022-11-21
 */
@Service
public class GcProjectFlowServiceImpl implements IGcProjectFlowService 
{
    @Autowired
    private GcProjectFlowMapper gcProjectFlowMapper;

    /**
     * 查询工程流程图
     * 
     * @param id 工程流程图主键
     * @return 工程流程图
     */
    @Override
    public GcProjectFlow selectGcProjectFlowById(Long id)
    {
        return gcProjectFlowMapper.selectGcProjectFlowById(id);
    }

    /**
     * 查询工程流程图列表
     * 
     * @param gcProjectFlow 工程流程图
     * @return 工程流程图
     */
    @Override
    public List<GcProjectFlow> selectGcProjectFlowList(GcProjectFlow gcProjectFlow)
    {
        return gcProjectFlowMapper.selectGcProjectFlowList(gcProjectFlow);
    }

    /**
     * 新增工程流程图
     * 
     * @param gcProjectFlow 工程流程图
     * @return 结果
     */
    @Override
    public int insertGcProjectFlow(GcProjectFlow gcProjectFlow)
    {
        return gcProjectFlowMapper.insertGcProjectFlow(gcProjectFlow);
    }

    /**
     * 修改工程流程图
     * 
     * @param gcProjectFlow 工程流程图
     * @return 结果
     */
    @Override
    public int updateGcProjectFlow(GcProjectFlow gcProjectFlow)
    {
        return gcProjectFlowMapper.updateGcProjectFlow(gcProjectFlow);
    }

    /**
     * 批量删除工程流程图
     * 
     * @param ids 需要删除的工程流程图主键
     * @return 结果
     */
    @Override
    public int deleteGcProjectFlowByIds(String ids)
    {
        return gcProjectFlowMapper.deleteGcProjectFlowByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除工程流程图信息
     * 
     * @param id 工程流程图主键
     * @return 结果
     */
    @Override
    public int deleteGcProjectFlowById(Long id)
    {
        return gcProjectFlowMapper.deleteGcProjectFlowById(id);
    }
}
